package com.jxgc.file.oi;

public class textstudent {
    public static void main(String[] args) {
        //目标：面对对采对象快速入门。
        //1.创建1个学生对象，封装波妞的数据
        Student  s1 = new Student(); //用变量来记录学生数据
        s1.name = "波妞";
        s1.chinese = 100;
        s1.math = 100;

        s1.printTotalScore();
        s1.printAverageScore();

        //2.再创建一个学生对象，封装波在的
        Student  s2 = new Student(); //用变量来记录学生数据
        s2.name = "波在";
        s2.chinese = 85;
        s2.math = 65;

        s2.printTotalScore();
        s2.printAverageScore();

        System.out.println(s1);
        System.out.println(s2);   //s1s2 里存储到的是地址


    }
}
